

/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef __FILTER_H
#define __FILTER_H

#include "imath.h"

#define PI					            3.14159265358979f

typedef struct
{
  float input_data[3];
  float output_data[3];
}butterworthData_t;

typedef struct
{
  const float a[3];
  const float b[3];
}butterworthParameter_t;

float butterworth_lpf(float now_input,butterworthData_t *buffer, butterworthParameter_t *parameter);
void get_iir_factor(float *out_factor,float Time, float Cut_Off);
void iir_lpf_run(f_xyz_t *input_data,f_xyz_t *output_data,float lpf_factor);
void butterworth_lpf_run(f_xyz_t *input_Data , f_xyz_t *output_Data , butterworthParameter_t lpf_parameter);

#endif /* __FILTER_H */
